package com.bl.weilan.dao.repository;

import com.bl.weilan.dao.model.TradeAEntity;
import com.bl.weilan.dao.model.TradeBEntity;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

/**
 * Created by liangweikang on 19/7/14.
 */
public interface TradeBRepository extends JpaRepository<TradeBEntity, String> {

   Page<TradeBEntity> findByTradeAOrderByWeightDesc(String id, Pageable pageable);

   List<TradeBEntity> findByTradeAOrderByWeightDesc(String id);

   TradeBEntity findByName(String name);

}
